﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MaxLeaf.Platform.Contract;
using MaxLeaf.Platform.DataContract;
using CommonsLib.Utility;
using MaxLeaf.Platform.DALImplementation;

namespace MaxLeaf.Platform.BLLImplementation
{
    public class MtnBLL :BaseBLL, IMtn
    {
         

        public new object Select(object model, int intKeyValue)
        {

            return GetDataModelBLL(model.GetType().Name).Select(model, intKeyValue);
            
            
        }


        public new List<object> SelectDtl(object model, int intForeignKeyValue)
        {

            return GetDataModelBLL(model.GetType().Name).SelectDtl(model, intForeignKeyValue);
             


        }

        public new SelectResult SelectByCond(object model, List<AddInfo> lstAddInfo)
        {

            return GetDataModelBLL(model.GetType().Name).SelectByCond(model, lstAddInfo);



        }

        public new SumResult Sum(object model, List<AddInfo> lstAddInfo)
        {

            return GetDataModelBLL(model.GetType().Name).Sum(model, lstAddInfo);



        }
 
        public new object Add(object model)
        {

            return GetDataModelBLL(model.GetType().Name).Add(model);
           
          
        }

        

        public new object Update(object model)
        {

            return GetDataModelBLL(model.GetType().Name).Update(model);
            
            
        }

        public new bool Delete(object model)
        {
             
                return GetDataModelBLL(model.GetType().Name).Delete(model);
            
             
        }

        public new bool Undelete(object model)
        {

            return GetDataModelBLL(model.GetType().Name).Undelete(model);


        }
    }
}
